<extend name="Public/base" />

<block name="body">
	<!-- 标题栏 -->
	<div class="main-title">
		<h2><?php $bid=M('bid_list')->where(array('id'=>I('bid_id')))->find();echo $bid['name'] ?>————用户报价列表</h2>
	</div>
	<div class="cf">

    </div>
    <!-- 数据列表 -->
    <div class="data-table table-striped">
	<table class="">
    <thead>
        <tr>
		<th class="row-selected row-selected"><input class="check-all" type="checkbox"/></th>
		<th class="">时间</th>
		<th class="">用户名称</th>
		<th class="">用户竞拍数</th>
		<th class="">用户报价</th>
		<th class="">用户电话</th>
		<th class="">状态</th>
		</tr>
    </thead>
    <tbody>
		<notempty name="_list">
		<volist name="_list" id="vo">
	      <?php $user=M('agent')->field('uid,username,mobile')->where(array('uid'=>$vo['user_id']))->find(); ?>		
		<tr>
            <td><input class="ids" type="checkbox" name="id[]" value="{$vo.id}" /></td>
            <td>{$vo.create_time|time_format='Y-m-d H:i:s'} </td>
            <td>{$user.username}</td>
			<td>{$vo.user_number}</td>
			<td>{$vo.user_price}</td>
			<td>{$user.mobile}</td>
			<td>
				<if condition="$key eq 0">
					<if condition="$bid['end_time'] gt time()">
						预计竞得{$vo.user_number}台
						<else />
						已竞得{$vo.user_number}台
						<a href="{:U('orderList',array('id'=>$vo['id']))}">查看订单</a>
					</if>
				  <else/>
					未竞得
				</if>
			</td>
		</tr>
		</volist>
		<else/>
		<td colspan="7" class="text-center"> aOh! 暂时还没有内容! </td>
		</notempty>
	</tbody>
    </table>
	</div>
    <div class="page">
        {$_page}
    </div>
</block>

<block name="script">
	<script src="__STATIC__/thinkbox/jquery.thinkbox.js"></script>

	<script type="text/javascript">
        //导航高亮
        highlight_subnav('{:U("bidList")}');
	</script>
</block>
